package mypackage;

public class P230 {

	public static void main(String[] args) {

		int a[] = { 1, 9, 8, 2, 8, 2, 7, 3, 0, 10, 8, 4 };

		for (int i = 1; i < a.length; i++) {
			int j = i;

			while (j != 0 && a[j] < a[j - 1]) {
				int temp = a[j - 1];
				a[j - 1] = a[j];
				a[j] = temp;

				j--;
			}
		}
		
		for (int i = 0; i < a.length; i++)
			System.out.print(a[i] + " ");

	}

}
